package com.csst.bean;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Entity(name = "UserBank")
@Table(name = "UserBank")
public class UserBank implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = -1456357626952144L;
	@Override
	public String toString() {
		return "UserBank [bankId=" + bankId + ", btime=" + btime + ", cardId="
				+ cardId + ", customerName=" + customerName
				+ ", identityCardNum=" + identityCardNum + ", quickPayKey="
				+ quickPayKey + "]";
	}

	@Id
	@GeneratedValue(strategy = GenerationType.AUTO)
	@Column(name = "BankId", nullable = true)
	private Integer bankId;
	
	@Column(name = "CustomerName", length = 10)
	private String customerName;
	
	@Column(name = "IdentityCardNum", length = 50)
	private String identityCardNum;
	@Column(name = "cardId", nullable = true)
	private String cardId;
	
	@Column(name = "QuickPayKey", length = 50)
	private String quickPayKey;
	
	@Column(name = "BTime", length = 50)
	private String btime;

	@OneToOne
	@JoinColumn(name = "UserId", insertable = true, unique = true)
	private User user;

	public Integer getBankId() {
		return bankId;
	}

	public void setBankId(Integer bankId) {
		this.bankId = bankId;
	}

	public User getUser() {
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}

	public void setCardId(String cardId) {
		this.cardId = cardId;
	}

	public String getCardId() {
		return cardId;
	}

	public String getQuickPayKey() {
		return quickPayKey;
	}

	public void setQuickPayKey(String quickPayKey) {
		this.quickPayKey = quickPayKey;
	}

	public void setBtime(String btime) {
		this.btime = btime;
	}

	public String getBtime() {
		return btime;
	}

	public String getCustomerName() {
		return customerName;
	}

	public void setCustomerName(String customerName) {
		this.customerName = customerName;
	}

	public String getIdentityCardNum() {
		return identityCardNum;
	}

	public void setIdentityCardNum(String identityCardNum) {
		this.identityCardNum = identityCardNum;
	}
}
